package maxssina.activity;

import maxssina.app.APP;
import android.app.ActivityGroup;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.widget.RelativeLayout;
import android.widget.TextView;

public class MainActivityGroup extends ActivityGroup {
	private RelativeLayout mInfoView;
	private TextView mTextViewTitle;
	private TextView mTextViewName;
	private APP mApp;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		requestWindowFeature(Window.FEATURE_NO_TITLE);
		setContentView(R.layout.group_main);
		mApp = ((APP) getApplicationContext());
		initView();
	}

	private void initView() {
		mInfoView = (RelativeLayout) findViewById(R.id.layout_info);
		mInfoView.addView(getLocalActivityManager().startActivity(
				"main",
				new Intent(MainActivityGroup.this, MainActivity.class)
						.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP))
				.getDecorView());

		mTextViewTitle = (TextView) findViewById(android.R.id.title);
	}
}
